# VERSION 0.0.1
# 默认ubuntu server长期支持版本，当前是14.04
FROM ubuntu:14.04
# 签名
MAINTAINER yangpengfei "jrunner@126.com"

# 更新源，安装vim
RUN apt-get update
RUN apt-get install -y vim
RUN apt-get install -y git

RUN echo "设置MAVEN_HOME环境变量"
ENV MAVEN_HOME /opt/swap/common/maven
ENV PATH $MAVEN_HOME/bin:$PATH

RUN echo "设置JAVA_HOME环境变量"
ENV JAVA_HOME /opt/swap/common/jdk7
ENV CLASSPATH  .:$JAVA_HOME/lib:$JAVA_HOME/jre/lib:$CLASSPATH
ENV PATH $JAVA_HOME/bin:$JAVA_HOME/jre/bin:$PATH

#登录容器后，所在的目录
WORKDIR /opt/swap/jenkins

#共享的挂在点
VOLUME /opt/swap/jenkins
VOLUME /opt/swap/common/jdk7
VOLUME /opt/swap/common/repository
VOLUME /opt/swap/common/maven

#容器jensins对外接口
EXPOSE 8001

# 设置Tomcat7初始化运行
#ENTRYPOINT service tomcat7
